<template>
  <div>
    <span>新增</span>
    <div class="box" :mode1="from">
      <el-input v-model="from.entCreditcode" placeholder="社会信用代码" />
      <el-input v-model="from.entShareholderamount" placeholder="持股份额" />
      <el-input v-model="from.entShareholderdid" placeholder="证件号码" />
      <el-input v-model="from.entShareholderdocuments" placeholder="证件类型" />
      <el-input
        v-model="from.entShareholderid"
        placeholder="企业股东信息表id"
      />
      <el-input v-model="from.entShareholdername" placeholder="股东名册" />
      <el-input v-model="from.entShareholderratio" placeholder="持股比例" />
      <el-input v-model="from.entShareholdertype" placeholder="股东类型" />
    </div>
    <el-button type="primary" @click="tijiao()">提交</el-button>
  </div>
</template>
  <script setup >
import { ref } from "vue";
import { useRouter } from "vue-router";
import { ElNotification } from "element-plus";
import "element-plus/es/components/notification/style/css";
import { xinzeng } from "@/apis/Sltapi/dudong";
var router = useRouter();

var from = ref({
  entCreditcode: "" /* 社会信用代码 */,
  entShareholderamount: "" /*持股份额*/,
  entShareholderdid: "" /*证件号码*/,
  entShareholderdocuments: "" /*证件类型*/,
  entShareholderid: "" /*企业股东信息表id*/,
  entShareholdername: "" /*股东名册*/,
  entShareholderratio: "" /*持股比例*/,
  entShareholdertype: "" /*股东类型*/,
});

var tijiao = async () => {
  var res = await xinzeng(from.value);
  ElNotification.success({ message: "添加成功!" });
  console.log(res);
};
</script>
  
  <style scoped>
.el-input {
  margin-top: 20px;
}
.el-button {
  margin-top: 40px;
}
</style>